#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QWidget>
#include "window/head.h"
#include "window/middle.h"
#include "window/tail.h"
#include <QStackedLayout>
#include "forget.h"
#include "window/AdminWindow/adminwindow.h"
#include "window/UserWindow/userwindow.h"
#include "enroll.h"

QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE

class MainWindow : public QWidget{
    Q_OBJECT

public:
    MainWindow(QWidget *parent = nullptr);
    ~MainWindow();

public slots:
    void toggleMinimize() {
       if (window()->isFullScreen()) {  //窗口是否全屏
           window()->showNormal();
       } else {
           window()->showFullScreen();
       }
    }


private:
    Ui::MainWindow *ui;
    Head *m_pHead;
    Middle *m_pMiddle;
    Tail *m_pTail;
    QStackedLayout *m_pStackedLayout;
    Forget *m_pForget;
    AdminWindow *m_pAdminWindow;
    UserWindow *m_pUserWindow;
    Enroll *m_pEnroll;

};
#endif // MAINWINDOW_H
